package com.wufun.overseas.adapters;

import android.content.Context;
import android.util.Log;
import android.view.ViewGroup;

import com.wufun.overseas.models.bean.GameTransferBean;
import com.wufun.overseas.view.GameTransferListItem;

/**
 * Author: hest
 * Date:  2016/5/4
 * 面传中选游戏列表适配器
 */
public class GameTransferListAdapter extends RecyclerViewBaseAdapter<GameTransferBean, GameTransferListItem> {
    private static final String TAG = GameTransferListAdapter.class.getSimpleName();

    boolean mSending=false;

    public GameTransferListAdapter(Context mContext) {
        this.mContext = mContext;
    }

    public void setSending(boolean sending){
        mSending=sending;
    }

    @Override
    protected GameTransferListItem onCreateItemView(ViewGroup parent, int viewType) {
        return new GameTransferListItem(mContext);
    }

    @Override
    public void onBindViewHolder(ViewWrapper<GameTransferListItem> holder, int position) {
        if (holder instanceof ViewWrapper) {
            GameTransferListItem item = holder.getView();
            item.bind(position,arrys,mSending);
            Log.d(TAG, "onBindViewHolder: "+position);

        }
    }
}
